package com.chucang.shucang.ttp.feign;

import com.chucang.shucang.common.base.constant.SecurityConstant;
import com.chucang.shucang.common.base.utils.R;
import com.chucang.shucang.ttp.feign.vo.UserCollectionHoldEntity;
import com.chucang.shucang.ttp.feign.vo.WalletDeductionVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

/**
 * @author flitsneak
 * @email flitsneak@gmail.com
 * @date 2022/10/4 14:13
 * @description
 */
@FeignClient(contextId = "ttp-user", value = "shucang-usr")
public interface UserService {

    @GetMapping("/usr/usercollectionhold/addCollectionHold")
    R<String> addCollectionHold(@RequestBody UserCollectionHoldEntity userCollectionHoldEntity, @RequestHeader(SecurityConstant.FROM) String from);

    @GetMapping("/usr/usercollectionhold/updateCollectionHold")
    R<String> updateCollectionHold(@RequestBody UserCollectionHoldEntity userCollectionHoldEntity, @RequestHeader(SecurityConstant.FROM) String from);

    @GetMapping("/usr/userbillrecord/finishBill/{billSn}")
    R<String> finishBill(@PathVariable("billSn") String billSn, @RequestHeader(SecurityConstant.FROM) String from);

    @PostMapping("/usr/userwallet/walletDeduction")
    R<String> walletDeduction(@RequestBody WalletDeductionVO walletDeductionVO, @RequestHeader(SecurityConstant.FROM) String from);
}
